<div class="layui-card">
    <div class="layui-card-body">
        <form class="layui-form" action="" method="post" id="cp-form" enctype="multipart/form-data">
            <div class="layui-tab">
                <ul class="layui-tab-title">
                    <li class="layui-this">基础</li>
                </ul>
                <div class="layui-tab-content">
                    <div class="layui-tab-item layui-show">
                        <div class="layui-form-item">
                            <label class="layui-form-label">广告标题 <span class="request-tips">*</span></label>
                            <div class="layui-input-block">
                                <input type="text" name="title"  value="" required lay-verify="required" placeholder="广告标题" autocomplete="off" class="layui-input">
                            </div>
                        </div>

                        <div class="layui-form-item">
                            <label class="layui-form-label">广告链接 <span class="request-tips">*</span></label>
                            <div class="layui-input-block">
                                <input type="text" name="url_link"  value="" required lay-verify="required" placeholder="广告链接" autocomplete="off" class="layui-input">
                            </div>
                        </div>

                        <div class="layui-form-item">
                            <label class="layui-form-label">广告封面 <span class="request-tips">*</span></label>
                            <div class="layui-input-block">
                                <button type="button" class="layui-btn" id="test1">
                                    <i class="layui-icon">&#xe67c;</i>上传封面
                                </button>
                            </div>
                            <div class="layui-input-block">
                                <table class="layui-table" id="app-photo">
                                    <tr>
                                        <td>
                                            <input type="text" class="layui-input" name="photo" value="">
                                        </td>
                                        <td>
                                            <img src="" alt="" width="150" >
                                        </td>
                                    </tr>
                                </table>
                            </div>
                        </div>

                        <div class="layui-form-item">
                            <label class="layui-form-label">展现状态 <span class="request-tips">*</span></label>
                            <div class="layui-input-block">
                                <input type="radio" name="type" class="layui-input" title="默认" value="0" checked>
                                <input type="radio" name="type" class="layui-input" title="弹窗" value="1" {if isset($ad.type) and $ad.type eq 1}checked{/if}>
                            </div>
                        </div>

                        <div class="layui-form-item">
                            <label class="layui-form-label">访问状态 <span class="request-tips">*</span></label>
                            <div class="layui-input-block">
                                <input type="radio" name="status" class="layui-input" title="开启" value="1" checked>
                                <input type="radio" name="status" class="layui-input" title="禁用" value="0" {if isset($ad.status) and $ad.status eq 0}checked{/if}>
                            </div>
                        </div>
                        <div class="layui-form-item">
                            <label class="layui-form-label">有效时间 <span class="request-tips">*</span></label>
                            <div class="layui-input-block">
                                <input type="text" name="datetime"  value="" id="datetime" required lay-verify="required" placeholder="有效时间" autocomplete="off" class="layui-input">
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-input-block">
                    <div class="layui-text">带 * 号的为必填项</div>
                    <button class="layui-btn" lay-submit lay-filter="formDemo">保存</button>
                    <a href="javascript:history.go(-1);" class="layui-btn layui-btn-primary">返回</a>
                </div>
            </div>
        </form>
    </div>
</div>
